Versions:

  • 3.2.0
  • 3.1.0
  • 3.0.0
  • 2.2.0
  • 2.1.0
  • 2.0.0
  • 1.1.0
  • 1.0.1

Sloc (Source Lines Of Code) is a .NET global command-line tool published by coldhighsun, currently available in version 3.2.0, with a total of 8 versions released over the course of its development history. As the name suggests, the software serves the purpose of counting lines of source code, a common requirement in software development, project assessment, and code base analysis. Falling into the category of developer utilities and code metrics tools, Sloc is distributed as a .NET global tool, which means it can be installed and invoked directly from the command line on systems equipped with the appropriate .NET runtime environment. The tool analyzes files individually rather than producing only a single summary figure, examining each file to distinguish between code lines, comment lines, and blank lines. This separation allows developers and analysts to understand not just the raw size of a code base but also its composition, such as how heavily a project is commented or how much whitespace it contains relative to executable logic. After performing this per-file analysis, Sloc aggregates the results by programming language, making it suitable for projects that mix multiple languages within a single repository, since each language's contribution to the overall code base is reported distinctly. Typical use cases include measuring project size for estimation and reporting purposes, tracking code growth over time, evaluating documentation density through comment line counts, and generating quick statistics during audits, code reviews, or migration planning. Because it operates from the command line, Sloc fits naturally into scripting workflows, continuous integration pipelines, and other automated environments where repeatable, machine-readable analysis of source trees is required. Users can select from the available released versions, with version 3.2.0 representing the current release at the time of this catalog entry.

Tags: